#ifndef _NE_PIANO_KEYBOARD_H_
#define _NE_PIANO_KEYBOARD_H_

#include <audio/MIDI/MIDIPitch.h>

namespace ne
{
    class PianoKeyboard
    {
        public:
            PianoKeyboard();

            void setKeyUp(const MIDIPitchType key);
            bool isKeyUp(const MIDIPitchType key) const;

            void setKeyDown(const MIDIPitchType key);
            bool isKeyDown(const MIDIPitchType key) const;

            void reset();

            ~PianoKeyboard();

        private:
            PianoKeyboard(const PianoKeyboard &);

            PianoKeyboard& operator = (const PianoKeyboard &);

        public:
            static bool IsPianoKey(const MIDIPitchType key);
            static bool IsBlackKey(const MIDIPitchType key);
            static bool IsWhiteKey(const MIDIPitchType key);

        public:
            static const uint32_t KEYBOARD_KEYS_NUM;
            static const uint32_t MIN_KEYBOARD_KEY;
            static const uint32_t MAX_KEYBOARD_KEY;
            static const uint32_t OCTAVE_KEYS;
            static const uint32_t BLACK_KEYS_NUM;
            static const uint32_t WHITE_KEYS_NUM;
            static const uint32_t BLACK_KEYS[5];
            static const uint32_t WHITE_KEYS[7];

        private:
            bool mKeysDown[88];
    };
}

#endif
